package com.icoolkj.security.springboot.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @author icoolkj
 * @version 1.0
 * @description  配置相当于 Springmvc.xml 文件
 * @createDate 2025/02/06 20:40
 */
@Configuration
public class WebConfig implements WebMvcConfigurer {

    @Override
    public void addViewControllers(ViewControllerRegistry registry) {
        registry.addViewController("/").setViewName("redirect:/login");
        //registry.addViewController("/login-view").setViewName("login");
    }

}
